<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<title>GMC Project</title>

<link rel="stylesheet" media="screen" href="<?php echo $this->config->item('staticPath'); ?>/css/login/reset.css" />
<link rel="stylesheet" media="screen" href="<?php echo $this->config->item('staticPath'); ?>/css/login/grid.css" />
<link rel="stylesheet" media="screen" href="<?php echo $this->config->item('staticPath'); ?>/css/login/style.css" />
<link rel="stylesheet" media="screen" href="<?php echo $this->config->item('staticPath'); ?>/css/login/messages.css" />
<link rel="stylesheet" media="screen" href="<?php echo $this->config->item('staticPath'); ?>/css/login/forms.css" />

<!--[if lt IE 8]>
<link rel="stylesheet" media="screen" href="<?php echo $this->config->item('staticPath'); ?>/css/login/ie.css" />
<![endif]-->

<!--[if lt IE 9]>
<script src="<?php echo $this->config->item('staticPath'); ?>/js/html5.js"></script>
<script src="<?php echo $this->config->item('staticPath'); ?>/js/PIE.js"></script>
<script src="<?php echo $this->config->item('staticPath'); ?>/js/IE9.js"></script>
<![endif]-->

<!-- jquerytools -->
<script type="text/javascript" src="<?php echo $this->config->item('staticPath'); ?>/js/jquery.tools.min.js"></script>
<script type="text/javascript" src="<?php echo $this->config->item('staticPath'); ?>/js/jquery.cookie.js"></script>
<script type="text/javascript" src="<?php echo $this->config->item('staticPath'); ?>/js/jquery.ui.min.js"></script>
<script type="text/javascript" src="<?php echo $this->config->item('staticPath'); ?>/js/global.js"></script>

<!-- THIS SHOULD COME LAST -->
<!--[if lt IE 9]>
<script type="text/javascript" src="<?php echo $this->config->item('staticPath'); ?>/js/ie.js"></script>
<![endif]-->

<script> 
$(document).ready(function(){
    $.tools.validator.fn("#username", function(input, value) {
        return value!='Username' ? true : {     
            en: "Please complete this mandatory field"
        };
    });
    
    $.tools.validator.fn("#password", function(input, value) {
        return value!='Password' ? true : {     
            en: "Please complete this mandatory field"
        };
    });

    var form = $("#form").validator({ 
    	position: 'bottom left', 
    	offset: [5, 0],
    	messageClass:'form-error',
    	message: '<div><em/></div>' // em element is the arrow
    }).attr('novalidate', 'novalidate');
});
</script> 
</head>
<?php
	if(!$this->session->userdata('session_user')) {
?>
<body class="login">
    <div class="login-box main-content">
      <header>
          <ul class="action-buttons clearfix fr">
          </ul>
          <h2>Login.</h2>
      </header>
    	<section>
    		<div class="message <?php echo $messageType;?>"><?php echo $message;?></div>
    		<form id="form" action="" method="post" class="clearfix">
			<p>
				<br/>
				<input type="text" id="username"  class="large" value="" name="username" required="required" placeholder="Username" />
				<br/>
				<br/>
                 <input type="password" id="password" class="large" value="" name="password" required="required" placeholder="Password" />
				 <br/>
			</p>
			<p class="clearfix">
				<span class="fl">
					<input type="checkbox" id="remember" class="" value="1" name="remember"/>
					<label class="choice" for="remember">Remember me </label>
				</span>
			</p>
			<p class="clearfix">
				<span class="fl">
				  <button class="large button button-gray fr" type="submit">Login</button>
				</span>
			</p>			
		</form>
    	</section>
    </div>
	<?php }?>
</body>
</html>
